<template>
	<view class="pt-step">
		<view class="pt-step-item" v-for="(data,index) in list" :key="index">
			<image :src="data.image" mode="widthFix" :style="'width:'+size+'rpx;height:'+size+'rpx'"></image>
			<!-- <u-image :src="data.image" class="image">
				<u-loading slot="loading"></u-loading>
			</u-image> -->
			<text :style="colorFun">{{data.name}}</text>
		</view>
	</view>
</template>

<script>
	export default {
		props: {
			size: {
				type: String,
				default: '48'
			},
			color: {
				type: String,
				default: ''
			},
			list: {
				type: Array,
				default () {
					return [];
				}
			}
		},
		data() {
			return {
				
			};
		},
		computed: {
			colorFun(){
				if(this.color){
					return 'color:' + this.color
				}
			}
		}
	}
</script>

<style lang="scss">
	.pt-step{
		display: flex;
		position: relative;
		z-index: 11;
		padding: 0 30rpx;
		.pt-step-item{
			flex: 1;
			text-align: center;
			padding: 80rpx 0;
			image{
				display: inline-block;
				width: 48rpx;
				height: 48rpx;
			}
			text{
				display: block;
				font-size: 24rpx;
				color: #666;
				margin-top: 20rpx;
			}
		}
	}
</style>